import request from '@/utils/request'
const api_video_name = '/edu/service/video'
const api_AliYunvideo_name='/edu/vod/video'
export default {
    // 添加小节
    addVideoInfo(video) {
        return request({
            url: `${api_video_name}/addVideo`,
            method: 'post',
            data: video
        })
    },
    // 根据Id查询章节
    getVideoById(videoId) {
        return request({
            url: `${api_video_name}/getVideo/${videoId}`,
            method: 'get'
        })
    },
    // 根据Id修改章节
    updateVideo(video) {
        return request({
            url: `${api_video_name}/updateVideo`,
            method: 'post',
            data: video
        })
    },
    // 根据Id删除章节
    deleteVideo(videoId) {
        return request({
            url: `${api_video_name}/deleteVideo/${videoId}`,
            method: 'delete'
        })
    },
     // 根据Id删除视频
     deleteAliYunVideo(videoId) {
        return request({
            url: `${api_AliYunvideo_name}/removeAliYunVideo/${videoId}`,
            method: 'delete'
        })
    }
}
